package leetcode.D2000.T1462;

import util.GraphUtil;

import java.util.List;

/**
 * @File Info: leetcode -- <M1462>
 * @Author: 18362
 * @Create: 2022-03-17 13:31:23 星期四
 */
public class M1462 {
    public static void main(String[] args) {
        int numCourses = 5;
        int[][] prerequisites = GraphUtil.parseGraph("[[0,1],[1,2],[2,3],[3,4]]");
        int[][] query = GraphUtil.parseGraph("[[0,4],[4,0],[1,3],[3,0]]");
        List<Boolean> results = new Solution().checkIfPrerequisite(numCourses, prerequisites, query);
        results.forEach(System.out::println);
    }
}
